package work.xiaohong.jijin.entity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

import java.io.Serializable;
import java.time.LocalDateTime;

import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_ONLY;

/**
 * 
 * @author xiaohong
 * @since 2021-11-20 17:46:23
 */
@Getter
@Setter
@TableName("jijin_zixuan")
@Schema(name = "Zixuan对象", description = "")
public class Zixuan implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "code", type = IdType.ASSIGN_ID)
    private String code;

    @TableField("name")
    private String name;

    @Schema(description = "创建时间",accessMode = READ_ONLY)
    @TableField(value = "gmt_create", fill = FieldFill.INSERT)
    private LocalDateTime gmtCreate;

    @Schema(description = "更改时间",accessMode = READ_ONLY)
    @TableField(value = "gmt_modified", fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime gmtModified;

    @Schema(description = "乐观锁",accessMode = READ_ONLY)
    @TableField("version")
    @Version
    private Integer version;

}
